A welding robot, sealing robot, etc., are arranged so that the position of a weld line or sealing line is detected on a real-time basis by means of a sensor, such as a laser sensor, mounted on the distal end portion of a robot arm; the measurement result is delivered to a control device, and the weld line or sealing line is traced by means of a welding torch or sealing head.
The laser sensor applies a laser beam to an object, a reflected light beam is seized by means of a light sensing element, and the distance (position of the object) from the object is measured on the basis of the principle of triangulation. By scanning the laser beam by means of a rocking mirror, the distance from the object is continuously measured, whereby sectional data of the object with respect to the scanning direction (i.e., data indicative of a surface configuration in a section of the object) are obtained by one scanning cycle. The weld line position or sealing position is obtained from these sectional data.
When using the laser sensor of this type, the degree of reflection of the laser beam varies depending on the surface condition of the object, so that the output of a laser generator should be adjusted accordingly. Further, reflected light beams include a primary reflected light beam, which is obtained when an applied laser beam is reflected by the surface of the object and is incident upon the light sensing element, a secondary reflected light beam, which is obtained when the primary reflected light beam is further reflected by the surface of the object and is incident, etc. In order to detect the object position accurately, therefore, the primary and secondary reflected light beams must be distinguished from each other as they are detected, so that various detection parameters, such as a threshold value, for discriminating these reflected light beams must be adjusted.
Conventionally, the output of the laser generator and the various detection parameters used to be adjusted on the basis of measurement results are obtained by activating the sensor in several suitable places.
According to this method, the detection behavior of the sensor during a tracking operation performed on a real-time basis cannot be followed, so that whether the respective set values of the various parameters are optimum or not can be determined only indirectly by the way the operation for welding or sealing is finished. Thus, if the measurement conditions during actual operation are not known well, this will cause the problems such as those discussed below.
(1) The sensor will not be able to fully perform its function. For example, even if the detection rate can be improved by optimally selecting the parameters, the detection behavior cannot be followed precisely, so that the detection rate cannot be improved. If the detection rate has dropped, the accuracy falls naturally, so that the sensor will no longer be good enough for application to some kinds of objects.
(2) Since the influences of modification of the parameters cannot be followed accurately, it is difficult to determine optimum set values.